import request from '@/utils/request'

export function getInfo2(articleId) {
  return request({
    url: '/od/comment/'+articleId,
    method: 'get',
  });
}

export function listComment(query) {
  return request({
    url: '/od/comment/list',
    method: 'get',
    params: query
  })
}

export function addComment(data) {
  return request({
    url: '/od/comment',
    method: 'post',
    data: data
  })
}

export function delComment(id) {
  return request({
    url: '/od/comment/' + id,
    method: 'delete'
  })
}

export function getComment(id) {
  return request({
    url: '/od/comment/' + id,
    method: 'get'
  })
}

export function updateComment(data) {
  return request({
    url: '/od/comment',
    method: 'put',
    data: data
  })
}

export function addCommentlike(data) {
  return request({
    url: '/od/commentlike',
    method: 'post',
    data: data
  })
}

export function delCommentlike(id) {
  return request({
    url: '/od/commentlike/' + id,
    method: 'delete'
  })
}

export function listCommentlike(query) {
  return request({
    url: '/od/commentlike/list',
    method: 'get',
    params: query
  })
}



